package com.mce.nebula.entity;

import com.mce.nebula.common.BaseEntity;
import jakarta.persistence.*;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 团队角色权限实体
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Entity
@Table(name = "team_role_permission", 
       uniqueConstraints = @UniqueConstraint(columnNames = {"role_id", "permission_code"}))
public class TeamRolePermission extends BaseEntity {
    
    @Column(name = "role_id", length = 32, nullable = false)
    private String roleId;
    
    @Column(name = "permission_code", length = 64, nullable = false)
    private String permissionCode;
    
    @Column(name = "permission_name", length = 128)
    private String permissionName;
    
    @Column(name = "permission_desc", length = 256)
    private String permissionDesc;
    
    @Column(name = "is_active", nullable = false)
    private Boolean isActive = true;
    
    @Column(name = "enterprise_id", length = 32)
    private String enterpriseId;
}





